Fix warning in .Pro build by forcing HAVE_UNISTD
authorRobert Lipe <robertlipe@users.noreply.github.com>
Mon, 30 Apr 2018 06:12:35 +0000 (01:12 -0500)
committerGitHub <noreply@github.com>
Mon, 30 Apr 2018 06:12:35 +0000 (01:12 -0500)
I'm not sure if it's new in Qt 5.9, but it's trivial (I think) to fix and harmless. When building files like gzread and gzwrite, MacOS would complain that we were missing declarations to extremely well known system functions (write, close, read, seek, ...) Those live in <unistd.h>, so we nudge the Makefile generator to trigger its inclusion for MacOS and Linux.

GPSBabel.pro

index c73807837569a4d8fc9e146bc6cad6622a1bb844..2642a6c9576e9c6e0f615da9119f6c21f6ea1c9c 100644 (file)
@@ -135,7 +135,7 @@ HEADERS =  \
 INCLUDEPATH += zlib
 
 macx|linux {
-  DEFINES += HAVE_NANOSLEEP HAVE_LIBUSB HAVE_GLOB
+  DEFINES += HAVE_NANOSLEEP HAVE_LIBUSB HAVE_GLOB HAVE_UNISTD_H
   SOURCES += gbser_posix.cc
   JEEPS += jeeps/gpslibusb.cc
   INCLUDEPATH += jeeps